<?php if (!defined('THINK_PATH')) exit();?><div style="float:left">
	<ul class="nav nav-list bs-docs-sidenav" style="margin:0;width:100px">
		<li><a href="javascript:getTemplateList(0)" style="text-align:left;"><i class="icon-chevron-right"></i>个人收藏</a></li>
		<?php if(is_array($cate)): $i = 0; $__LIST__ = $cate;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$vo): $mod = ($i % 2 );++$i;?><li><a href="javascript:getTemplateList(<?php echo ($vo["category_id"]); ?>)" id="group_<?php echo ($vo["group_id"]); ?>"><i class="icon-chevron-right"></i><?php echo ($vo["category_name"]); ?></a></li><?php endforeach; endif; else: echo "" ;endif; ?>
	</ul>
</div>
<div class="template-content" id="">
<div style="width:400px;float:right;">
	<table class="table table-condensed table-bordered table-hover holiday-content" style="height:100%">
		<thead><tr><td>短信内容</td><td>操作</td></tr></thead>
		<tbody>
			<?php if(is_array($list)): $i = 0; $__LIST__ = $list;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$vi): $mod = ($i % 2 );++$i;?><tr><td><a href="javascript:void(0)" onclick="insertMegContent($(this).html());"><?php echo ($vi["sms_content"]); ?></a></td><td width=30><i class="icon-th-list"></i><i class="icon-trash"></i></td></tr><?php endforeach; endif; else: echo "" ;endif; ?>
		</tbody>
	</table>
</div>
</div>
<div class="pagination" style="float:right">
	<?php echo ($page); ?>
</div>
<script>
	function getTemplateList($categoryID){
		$.ajaxload("__APP__/SMS/smsTemplateInsert/category_id/" + $categoryID,".template-content");
	}
	//点击短信库内容，后插入发送短信界面短信内容事件
	function insertMegContent(content){
		$(".modal-dialog").fadeOut(500,function(){
			$("#sendcontent").val("").val(content);
			var length=$("#sendcontent").val().length;
			statWordNum('',length);
		});
		clearDynamicHtml();
	}
</script>